﻿Imports System.Collections.Generic
Imports Pop.Api.Response
Imports Pop.Api.Util

Namespace Pop.Api.Request
    ''' <summary>
    ''' 7.6 (中级)获取用户的详细信息
    ''' </summary>
    Public Class GetUserDetailInfoRequest
        Inherits PopRequest(Of GetUserDetailInfoResponse)
        ''' <summary>
        ''' 回调函数前缀
        ''' </summary>
        Property Callback As String

        ''' <summary>
        ''' 填写要查的用户QQ号码。
        ''' </summary>
        Property UserUin As Nullable(Of Long)

#Region "Overrides"
        Protected Overrides Function GetApiName() As String
            Return "user.getUserDetailInfo"
        End Function

        Protected Overrides Function GetParameters() As IEnumerable(Of KeyValuePair(Of String, String))
            Dim parameters As New PopDictionary
            parameters.Add("callback", Me.Callback)
            parameters.Add("userUin", Me.UserUin)
            Return parameters
        End Function

        Protected Overrides Sub Validate()
            Me.UserUin.ValidateRequired("userUin")
        End Sub
#End Region

    End Class
End Namespace